package com.parking.order.model.form;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;

/**
 * 平台查询订单Form
 * */
@Data
@ApiModel("平台查询订单Form")
public class FindOrderPlatformForm {
    /**
     * 页数
     * */
    @ApiModelProperty("页数")
    @NotNull(message = "pageNum不为空")
    @Min(message = "pageNum为正数",value = 1)
    private Integer pageNum;
    /**
     * 每页大小
     * */
    @ApiModelProperty("每页大小")
    @NotNull(message = "pageSize不为空")
    @Min(message = "pageSize为正数",value = 1)
    private Integer pageSize;
    /**
     * 订单状态 0预定订单 1正在进行 2超时订单 3取消订单 4完成订单
     * */
    @ApiModelProperty("订单状态")
    @NotNull(message = "orderInfoState不能为空")
    @Min(message = "orderInfoState不存在",value = 0)
    @Max(message = "orderInfoState不存在", value = 4)
    private Integer orderInfoState;
    /**
     * 订单更多状态
     *        0预定订单 -> 0未支付 1已支付
     *        1正在进行 -> 0未入场 1已入场
     *        2超时订单 -> 0未出场 1未支付
     *        3取消订单 -> 0手动取消 1超时取消
     *        4完成订单 -> 0未评论 1好中评 2差评
     * */
    @ApiModelProperty("更多订单状态")
    @Min(message = "orderInfoStateFurther不存在",value = 0)
    @Max(message = "orderInfoStateFurther不存在", value = 2)
    private Integer orderInfoStateFurther;
    /**
     * 车位号 A001 - Z999
     * */
    @ApiModelProperty("车位号")
    @Pattern(message = "stallInfo不符合格式", regexp = "^[A-Z]{1}[0-9]{3}$")
    private String stallInfo;
    /**
     * 物业信息Id
     * */
    @ApiModelProperty("物业信息Id")
    @Min(message = "certifiedInfoId为正数",value = 0)
    private Integer certifiedInfoId;
}

